<template>
	<v-header/>
		<h5>{{ title }}</h5>
		<button @click="getTitle()">获取home组件里面的title</button>
</template>

<script>
	import Header from './Header'
	export default {
		data() {
			return {
				title: "首页组件title"
			}
		},
		methods: {
			getTitle() {
				alert(this.title)
			}
		},
		components: {
			"v-header": Header
		}
	}
</script>

<style lang="scss">
	h5 {
		text-align: center;
	}
</style>